3.203 \(\int \frac {\sin (x)}{\cot (x)+\csc (x)} \, dx\)

Optimal. Leaf size=6 \[ x-\sin (x) \]

[Out]

x-sin(x)

________________________________________________________________________________________

Rubi [A]  time = 0.07, antiderivative size = 6, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, integrand size = 10, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.300, Rules used = {4392, 2682, 8} \[ x-\sin (x) \]

Antiderivative was successfully verified.

[In]

Int[Sin[x]/(Cot[x] + Csc[x]),x]

[Out]

x - Sin[x]

Rule 8

Int[a_, x_Symbol] :> Simp[a*x, x] /; FreeQ[a, x]

Rule 2682

Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)/((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[(g*(g*Cos[e
 + f*x])^(p - 1))/(b*f*(p - 1)), x] + Dist[g^2/a, Int[(g*Cos[e + f*x])^(p - 2), x], x] /; FreeQ[{a, b, e, f, g
}, x] && EqQ[a^2 - b^2, 0] && GtQ[p, 1] && IntegerQ[2*p]

Rule 4392

Int[(cot[(c_.) + (d_.)*(x_)]^(n_.)*(a_.) + csc[(c_.) + (d_.)*(x_)]^(n_.)*(b_.))^(p_)*(u_.), x_Symbol] :> Int[A
ctivateTrig[u]*Csc[c + d*x]^(n*p)*(b + a*Cos[c + d*x]^n)^p, x] /; FreeQ[{a, b, c, d}, x] && IntegersQ[n, p]

Rubi steps

\begin {align*} \int \frac {\sin (x)}{\cot (x)+\csc (x)} \, dx &=\int \frac {\sin ^2(x)}{1+\cos (x)} \, dx\\ &=-\sin (x)+\int 1 \, dx\\ &=x-\sin (x)\\ \end {align*}

________________________________________________________________________________________

Mathematica [B]  time = 0.01, size = 14, normalized size = 2.33 \[ 2 \left (\frac {x}{2}-\frac {\sin (x)}{2}\right ) \]

Antiderivative was successfully verified.

[In]

Integrate[Sin[x]/(Cot[x] + Csc[x]),x]

[Out]

2*(x/2 - Sin[x]/2)

________________________________________________________________________________________

fricas [A]  time = 1.47, size = 6, normalized size = 1.00 \[ x - \sin \relax (x) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(x)/(cot(x)+csc(x)),x, algorithm="fricas")

[Out]

x - sin(x)

________________________________________________________________________________________

giac [B]  time = 0.21, size = 18, normalized size = 3.00 \[ x - \frac {2 \, \tan \left (\frac {1}{2} \, x\right )}{\tan \left (\frac {1}{2} \, x\right )^{2} + 1} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(x)/(cot(x)+csc(x)),x, algorithm="giac")

[Out]

x - 2*tan(1/2*x)/(tan(1/2*x)^2 + 1)

________________________________________________________________________________________

maple [B]  time = 0.10, size = 19, normalized size = 3.17 \[ -\frac {2 \tan \left (\frac {x}{2}\right )}{\tan ^{2}\left (\frac {x}{2}\right )+1}+x \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(x)/(cot(x)+csc(x)),x)

[Out]

-2*tan(1/2*x)/(tan(1/2*x)^2+1)+x

________________________________________________________________________________________

maxima [B]  time = 0.66, size = 38, normalized size = 6.33 \[ -\frac {2 \, \sin \relax (x)}{{\left (\frac {\sin \relax (x)^{2}}{{\left (\cos \relax (x) + 1\right )}^{2}} + 1\right )} {\left (\cos \relax (x) + 1\right )}} + 2 \, \arctan \left (\frac {\sin \relax (x)}{\cos \relax (x) + 1}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(x)/(cot(x)+csc(x)),x, algorithm="maxima")

[Out]

-2*sin(x)/((sin(x)^2/(cos(x) + 1)^2 + 1)*(cos(x) + 1)) + 2*arctan(sin(x)/(cos(x) + 1))

________________________________________________________________________________________

mupad [B]  time = 1.05, size = 6, normalized size = 1.00 \[ x-\sin \relax (x) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(x)/(cot(x) + 1/sin(x)),x)

[Out]

x - sin(x)

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {\sin {\relax (x )}}{\cot {\relax (x )} + \csc {\relax (x )}}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(x)/(cot(x)+csc(x)),x)

[Out]

Integral(sin(x)/(cot(x) + csc(x)), x)

________________________________________________________________________________________